Skip to main content

Webhook: TASK_CREATED

Description​

The TASK_CREATED webhook is triggered whenever a new task is successfully created. This event provides the details of the newly created task, enabling external systems to process or log the information.


Request Format​

The webhook sends an HTTP POST request with the following payload:

{
"entityId": "1d63907b-93ed-4188-8b5d-99292fceaae9",
"type": "TASK_CREATED",
"createdAt": "2024-12-16T10:00:00.000Z",
"data": {
"id": "1d63907b-93ed-4188-8b5d-99292fceaae9",
"organizationId": "9864d894-699a-4a00-8d4c-ae181215d721",
"locationId": "27b732ee-5921-475f-acd7-137fc4d5aa0f",
"startAt": "2024-12-16T11:00:00.000Z",
"endAt": "2024-12-16T13:00:00.000Z",
"name": "Task 1",
"assigneeIds": [
"6ad1a95b-ea50-4e23-8495-ef82900ca98d"
],
"recurrenceRule": null
}
}

Key Properties​

Top-Level Properties​

  • entityId: Unique identifier for the created task.
  • type: Specifies the webhook type (TASK_CREATED).
  • createdAt: Timestamp when the webhook was triggered (in ISO 8601 format).
  • data: Contains the task's properties.

Data Section​

  • id: Unique identifier for the task.
  • organizationId: The ID of the organization associated with the task.
  • locationId: The location where the task is assigned.
  • startAt: Start time of the task in ISO 8601 format.
  • endAt: End time of the task in ISO 8601 format.
  • name: Name or title of the task.
  • assigneeIds: Array of IDs of users assigned to the task.
  • recurrenceRule: Details of recurrence (if applicable).

Response Example​

A typical response payload confirming the creation of a new task:

{
"entityId": "1d63907b-93ed-4188-8b5d-99292fceaae9",
"type": "TASK_CREATED",
"createdAt": "2024-12-16T10:00:00.000Z",
"data": {
"id": "1d63907b-93ed-4188-8b5d-99292fceaae9",
"organizationId": "9864d894-699a-4a00-8d4c-ae181215d721",
"locationId": "27b732ee-5921-475f-acd7-137fc4d5aa0f",
"startAt": "2024-12-16T11:00:00.000Z",
"endAt": "2024-12-16T13:00:00.000Z",
"name": "Task 1",
"assigneeIds": [
"6ad1a95b-ea50-4e23-8495-ef82900ca98d"
],
"recurrenceRule": null
},
"id": 101
}

Benefits of TASK_CREATED Webhook​

  1. Real-Time Task Integration: Enables immediate synchronization of task information with external systems or workflows.
  2. Proactive Notifications: Ensures users or systems are aware of new tasks as soon as they are created.
  3. Automation: Facilitates automated workflows like notifications, reporting, or task delegation based on the received task data.

By using the TASK_CREATED webhook, systems and users can maintain up-to-date task information and automate processes effectively.